summaryrefslogtreecommitdiffstats
path: root/docusaurus/src/functions/typescriptNever.ts
blob: 42becd53ab52509fda44149ca09b5b52703c008a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
/* SPDX-License-Identifier: AGPL-3.0-or-later */

export default (typescriptNeverValue: never): never => {
  console.warn({ typescriptNeverValue });

  return typescriptNeverValue;
};

// How do I check that a switch block is exhaustive in TypeScript? - Stack Overflow
// https://stackoverflow.com/questions/39419170/how-do-i-check-that-a-switch-block-is-exhaustive-in-typescript